//
// Created by xzy.xiao on 2022/6/10.
//

#ifndef QT_DEMO_EVENTLABEL_H
#define QT_DEMO_EVENTLABEL_H

#include <QLabel>

class EventLabel : public QLabel {
protected:
    bool event(QEvent *e) override;
    void mouseMoveEvent(QMouseEvent *ev) override;
    void mousePressEvent(QMouseEvent *ev) override;
    void mouseReleaseEvent(QMouseEvent *ev) override;
    void closeEvent(QCloseEvent *event) override;
    bool myKeyEvent(QEvent *e);

private:
    bool ifContinueToClose();
};

#endif //QT_DEMO_EVENTLABEL_H
